package luj.groovy.excel.internal.table.create

import luj.groovy.excel.api.table.build.TableBuilder
import org.apache.poi.ss.usermodel.Sheet

class TableBuildStarter {

  TableBuildStarter(Sheet sheet) {
    _sheet = sheet
  }

  TableBuilder start() {
    def header = new BuildHeaderImpl()
    header._sheet = _sheet

    def builder = new BuildTableImpl()
    builder._sheet = _sheet
    builder._header = header
    return builder
  }

  private final Sheet _sheet
}
